home *** CD-ROM | disk | FTP | other *** search
/ Developer CD Series 1995 June: Reference Library / Dev.CD Jun 95 / Dev.CD Jun 95.toast / What's New? / Sample Code / QuickTime Sample Code / DTS QT Utilities.Apr-95 / Projects & Test Apps / MovieShell / Mac Framework / MacMain.c < prev    next >
Encoding:
C/C++ Source or Header  |  1995-04-16  |  1.1 KB  |  56 lines  |  [TEXT/MPCC]

  1. /*
  2.     File:        MovieShell.c
  3.  
  4.     Contains:    Simple Mac shell for testing QuickTime.
  5.  
  6.     Written by:    DTS
  7.  
  8.     Copyright:    © 1994-1995 by Apple Computer, Inc., all rights reserved.
  9.  
  10.     Change History (most recent first):
  11.  
  12.        <1>         12/20/94    khs        first file
  13.        
  14. */
  15.  
  16.  
  17. // INCLUDES
  18. #include <stdio.h>
  19. #ifdef __MWERKS__
  20. #include <sioux.h>
  21. #endif // __MWERKS__
  22.  
  23. #include "DTSQTUtilities.h"
  24. #include "MacFramework.h"
  25.  
  26.  
  27. // MAIN
  28. // ______________________________________________________________________
  29. void main(void)
  30. {
  31.     OSErr anErr;
  32.  
  33. // This is for controlling the sioux window under Metrowerks (5.0 forward)
  34. #ifdef USESIOUX    
  35.     SIOUXSettings.initializeTB = false;
  36.     SIOUXSettings.setupmenus = false;
  37. #endif // USESIOUX    
  38.  
  39.     InitStack(10*1024L);                        // Add 10k more to the stack, for possible QD and Sound Manager needs
  40.     InitMacEnvironment(10L);                    // 10 * MoreMasters
  41.     InitMenubar();
  42.     
  43.     if( !QTUIsQuickTimeInstalled() )
  44.         ExitToShell();
  45. #if powerc    
  46.     if( !QTUIsQuickTimeCFMInstalled() )
  47.         ExitToShell();                                // I could disable features as well.
  48. #endif 
  49.  
  50.     anErr = EnterMovies(); DebugAssert(anErr == noErr);
  51.     if(anErr != noErr)
  52.         ExitToShell();
  53.  
  54.     MainEventLoop();
  55. }
  56.